package core;

import javax.swing.JDialog;
import javax.swing.JFrame;
import javax.swing.JOptionPane;

public class PopUpTax {
	JDialog dialog;
	
	JOptionPane pPane = new JOptionPane("Tax field");
	Object[] options = new String[]{"Pay tax (10%)", "Pay sum"};

	public PopUpTax() {
		pPane.setOptions(options);
		dialog = pPane.createDialog(new JFrame(),"Tax");
	}
	
	public boolean payTaxQ(){
		dialog.show();
		Object obj = pPane.getValue();
		if(options[0].equals(obj))
			return true;
		else
			return false;
		
	}

}
